package com.leyou.user.userService;

import com.baomidou.mybatisplus.extension.service.IService;
import com.leyou.common.constants.RegexPatterns;
import com.leyou.pojo.dto.UserDto;
import com.leyou.user.entity.User;
import org.springframework.validation.annotation.Validated;

import javax.validation.constraints.Pattern;

public interface UserService extends IService<User> {
    /**
     * 根据用户名和密码查询参数
     * @param username
     * @param password
     * @return
     */
    UserDto queryUserByNameAndPsw(String username, String password);

    /**
     * 注册用户
     * @param username
     * @param password
     * @param phone
     * @param code
     */
    void registerUser(String username, String password, String phone, String code);


    /**
     * 发送短信验证码
     * @param phone
     */
    void sendSms(String phone);

    Boolean paramIsExist(String data, Integer type);
}
